package com.web3.management.entity;

import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.*;

/**
 * 全局配置实体类
 *
 * @author Web3 Management Team
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Entity
@Table(name = "configs")
public class Config extends BaseEntity {

    /**
     * 配置名称
     */
    @Column(name = "name", length = 100, nullable = false)
    private String name;

    /**
     * 配置文件路径
     */
    @Column(name = "file_path")
    private String filePath;

    /**
     * 配置内容（JSON格式）
     */
    @Lob
    @Column(name = "config_content", nullable = false)
    private String configContent;

    /**
     * 是否激活：1激活，0未激活
     */
    @Column(name = "is_active", nullable = false)
    private Integer isActive = 0;
}